package com.mtoolkit.jdbc.handler;

import java.sql.ResultSet;
import java.sql.SQLException;

/**
 * Result set handler callback interface.
 * 
 * @param	<T> result type.
 * 
 * @author 	<a href="mailto:xishizhang@gmail.com">ZhangShixi</a>
 * @version 1.0, 12/7/2011
 * @since 	JDK1.5
 */
public interface ResultSetHandler<T> {

    /**
     * Handles the result set.
     * 
     * @param  rs result set.
     * 
     * @return handled result set.
     * 
     * @throws SQLException if a sql error occurs whiling handle result set.
     */ 
    public T handle(ResultSet rs) throws SQLException;
    
}
